You are here: Symbol Reference > Dew Namespace > Dew.Stats Namespace > Dew.Stats.Units Namespace > Classes > StatTimeSerAnalysis Class > StatTimeSerAnalysis Methods > StatTimeSerAnalysis.BoxLjung Method
Dew Stats for .NET
ContentsIndexHome
PreviousUpNext
StatTimeSerAnalysis.BoxLjung Method

The box-Ljung statistics.

Syntax
C#
Visual Basic
public static double BoxLjung([In] TVec X, [In] int h);
Parameters 
Description 
[In] TVec X 
Defines the residuals of predicted values. 
[In] int h 
Defines the number of lags used in statistics. 

the Box-Ljung statistics.

The Ljung-Box test is based on the autocorrelation plot. However, instead of testing randomness at each distinct lag, it tests the "overall" randomness based on a number of lags. For this reason, it is often referred to as a "portmanteau" test. The Ljung-Box test statistics can be defined as follows: 

 

where n is the sample size, rho(j) is the autocorrelation at lag j, and h is the number of lags being tested. Actually we are testing the hypothesis:

  • H: The data are random.
  • Ha: The data are not random.

The Ljung-Box test is commonly used in ARIMA modeling. Note that it is applied to the residuals of a fitted ARIMA model, not the original series.

Copyright (c) 1999-2024 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!